﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;

namespace _2._13._2015_VehiclesInClass.Models
{
    public abstract class Vehicle
    {
        public string Make { get; set; }
        public string Model1 { get; set; }
        public int Year { get; set; }
        public int Id { get; set; }
    }

    public class Car : Vehicle {}
    public class Motorcycle : Vehicle { }
    public class Truck : Vehicle { }

    public class CreateViewModel
    {
        [DisplayName("Car Make"), Required]
        public string Make { get; set; }
        [DisplayName("Car Model"), Required]
        public string Model1 { get; set; }
        [DisplayName("Car Year")]
        public int Year { get; set; }
    }

    public class UpdateViewModel
    {
        public int Id { get; set; }
        public string Make { get; set; }
        public string Model1 { get; set; }
        public int Year { get; set; }
    }
}